package com.lf.data.check;

public class WebNodeOptionCheck extends Check {

    private String name = "\\w+";
    private String description = ".+";
    private String webNodeid = id;
    private String index = "\\d+";
    private String type = "\\w+";
    private String list = "0|1";

    public boolean checkName(String name) {
        return check(this.name, name);
    }

    public boolean checkDescription(String description) {
        return check(this.description, description);
    }

    public boolean checkWebNodeid(String webNodeid) {
        return check(this.webNodeid, webNodeid);
    }

    public boolean checkIndex(String index) {
        return check(this.index, index);
    }

    public boolean checkIndex(int index) {
        return index > 0;
    }

    public boolean checkType(String type) {
        return check(this.type, type);
    }

    public boolean checkList(String list) {
        return check(this.list, list);
    }

    public String getName() {
        return name;
    }

    public String getDescription() {
        return description;
    }

    public String getWebNodeid() {
        return webNodeid;
    }

    public String getIndex() {
        return index;
    }

    public String getType() {
        return type;
    }

    public String getList() {
        return list;
    }

}
